﻿using System;
using System.Collections.Generic;

namespace YummyGame.Framework
{
    public class ExpressionAdd : ExpressionOperation
    {
        public ExpressionAdd(Expression exp1, Expression exp2) : base(exp1, exp2)
        {

        }

        public override float Calculate()
        {
            return exp1.Calculate() + exp2.Calculate();
        }

        public override object Clone()
        {
            return new ExpressionAdd((Expression)(exp1.Clone()), (Expression)(exp2.Clone()));
        }
    }
}
